# PowerShell打包脚本
$VERSION = "1.0.0"
$APP_NAME = "ACMT"

# 构建release版本
cargo build --release

# 检查NSIS安装
if (-not (Test-Path "C:\Program Files (x86)\NSIS\makensis.exe")) {
    Write-Host "请先安装NSIS: https://nsis.sourceforge.io/Download"
    exit 1
}

# 生成安装程序
& "C:\Program Files (x86)\NSIS\makensis.exe" /DVERSION=$VERSION /DAPPNAME=$APP_NAME installer.nsi
